package com.ww.java17.records;

public class TestPerson {
    public static void main(String[] args) {
        Person p1 = new Person("Java老司机", 18, "深圳市宝安区");
        Person p2 = new Person("Go高手", 20, "深圳市南山区");
        PersonRecord p1Record = new PersonRecord(p1.getName(), p1.getAge());
        PersonRecord p2Record = new PersonRecord(p2.getName(), p2.getAge());
        System.out.println(p1Record);
        System.out.println(p2Record);
    }
}
